package com.ky.pro.java.rpc.core.config;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import org.springframework.boot.context.properties.ConfigurationProperties;

import java.util.HashMap;
import java.util.Map;

/**
 * @ClassName KyRpcProperties
 * @Description TODO
 * @Date 2022/1/1 15:04
 * @Author kevin
 **/
@ConfigurationProperties("ky.rpc")
@Getter
@Setter
@NoArgsConstructor
public class KyRpcProperties {

    Map<String, StubProperties> stubs = new HashMap<>();

    public StubProperties getStubProperties(String serviceName) {
        return stubs.get(serviceName);
    }

}
